<!DOCTYPE html>
<html>

<head>
    <!-- 页面meta -->
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <title>商品管理</title>
    <!-- Tell the browser to be responsive to screen width -->
    <meta content="width=device-width,initial-scale=1,maximum-scale=1,user-scalable=no" name="viewport">
    <link rel="stylesheet" href="../plugins/bootstrap/css/bootstrap.min.css">
    <link rel="stylesheet" href="../plugins/adminLTE/css/AdminLTE.css">
    <link rel="stylesheet" href="../plugins/adminLTE/css/skins/_all-skins.min.css">
    <link rel="stylesheet" href="../css/style.css">
    <script src="../plugins/jQuery/jquery-2.2.3.min.js"></script>
    <script src="../plugins/bootstrap/js/bootstrap.min.js"></script>
    <script src="../plugins/angularjs/angular.min.js"></script>
    <script src="../plugins/angularjs/pagination.js"></script>
    <link rel="stylesheet" href="../plugins/angularjs/pagination.css">
    <script src="../js/base_pagination.js"></script>
    <script src="../js/service/SchoolListService.js"></script>
    <script src="../js/service/uploadService.js"></script>
    <script src="../js/service/SystemService.js"></script>
    <script src="../js/controller/baseController.js"></script>
    <script src="../js/controller/SchoolListController.js"></script>
    <script src="../js/controller/uploadController.js"></script>
    <script src="../js/controller/SystemController.js"></script>



</head>

<body class="hold-transition skin-red sidebar-mini" ng-app="finance" ng-controller="SystemController">
<!-- .box-body -->

<div class="box-header with-border">
    <h3 class="box-title">系统管理</h3>
</div>

<div class="box-body">

    <!-- 数据表格 -->
    <div class="table-box">

            <!--工具栏-->
            <div class="box-tools pull-right">
                <div class="form-group form-inline">
                    <div class="btn-group">
                        <button type="button" class="btn btn-default" title="添加系统" data-toggle="modal" data-target="#editModal" ng-click="image_entity={}"><i class="fa fa-file-o"></i> 添加系统✔</button>
                    </div>
                </div>
            </div>

            <!--数据列表-->
            <table id="dataList" class="table table-bordered table-striped table-hover dataTable">
                <thead>
                <tr>
                    <td>序号</td>
                    <td>系统</td>
                    <td>模块</td>
                    <td>状态</td>
                    <td>操作</td>
                </tr>
                </thead>
                <tbody>

                </tbody>
            </table>

        </div>
        <!-- 数据表格 /-->

</div>
<!-- /.box-body -->
<!-- 编辑窗口 -->
<div class="modal fade" id="editModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
    <div class="modal-dialog" >
        <div class="modal-content">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
                <h3 id="myModalLabel">新增系统</h3>
            </div>
            <div class="modal-body">
                <table class="table table-bordered table-striped"  width="800px">
                    <tr>
                        <td>系统名称</td>
                        <td><input  class="form-control" placeholder="系统名称" ng-model="entity.name">  </td>
                    </tr>
                    <tr>
                        <td>系统描述</td>
                        <td><input  class="form-control" placeholder="系统描述" ng-model="entity.content">  </td>
                    </tr>
                    <tr>
                        <td>添加背景</td>
                        <td><input  class="form-control" placeholder="背景"  type="file" id="file"></td>
                        <td> <button ng-click="uploadFile()" class="btn btn-primary" type="button">
                            上传
                        </button></td>
                        <td> <img src="{{entity.pic}}" width="50px" height="50px" ng-model="entity.pic"></td>
                    </tr>

                    <table class="table table-bordered table-striped table-hover dataTable">
                        <div class="btn-group">
                            <button type="button" class="btn btn-default" title="新建" ng-click="addTableRow()" ><i class="fa fa-file-o"></i>新增系统模块</button>
                        </div>
                        <thead>
                            <th class="sorting">系统模块</th>
                        </thead>
                        <tbody>
                        <tr ng-repeat="pojo in entity.model">
                            <td>
                                <input  class="form-control" ng-model="pojo.text" placeholder="系统模块">
                            </td>
                            <td>
                                <button type="button" class="btn btn-default" title="删除" ng-click="deleteTableRow($index)" ><i class="fa fa-trash-o"></i> 删除</button>
                            </td>
                        </tr>
                        </tbody>
                    </table>

                </table>

            </div>
            <div class="modal-footer">
                <button class="btn btn-success" data-dismiss="modal" aria-hidden="true" ng-click="save()">保存</button>
                <button class="btn btn-default" data-dismiss="modal" aria-hidden="true">关闭</button>
            </div>
        </div>
    </div>
</div>

</body>

</html>